<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>关联值班</title>
		<link rel="stylesheet" href="../../js/plugins/layui-v2.4.5/layui/css/layui.css" />
		<link rel="stylesheet" href="../../css/reset.css" />
		<link rel="stylesheet" href="../../css/list.css" />
	</head>
	<body>
		<div class="p15">
			<table id="list" lay-filter="list"></table>
			<div class="layui-row save-btns" style="text-align: center;">
				<a href="javascript:;" class="layui-btn  layui-btn-normal">关联值班</a>
			</div>
		</div>
		<script src="../../js/jquery-3.3.1.min.js"></script>
		<script src="../../js/plugins/layui-v2.4.5/layui/layui.js"></script>
		<script>
			var data = [{
					id: 1,
					name: '网络组三班倒',
					startTime: '8:00',
					endTime: '8:00',
					dept:'网络组'
				},{
					id: 2,
					name: '网络组白倒',
					startTime: '8:30',
					endTime: '6:00',
					dept:'网络组'
				}
			];
			layui.use(['table'],function(){
				var table = layui.table;
				//第一个实例
				  table.render({
					elem: '#list'
					,height: '300'
					,url: '' //数据接口
					,page: true //开启分页
					,cols: [[ //表头
					{type:'checkbox'},
					  	{
					  		field: 'xh',
					  		title: '序号',
					  		width: 80,
					  		align: 'center',
					  		templet: function(d) {
					  			return d.LAY_INDEX;
					  		}
					  	}, {
					  		field: 'name',
					  		title: '计划名称',
					  		align: 'center'
					  	}, {
					  		field: 'startTime',
					  		title: '开始时间',
					  		align: 'center'
					  	}, {
					  		field: 'endTime',
					  		title: '结束时间',
					  		align: 'center'
					  	}, {
					  		field: 'dept',
					  		title: '值班部门',
					  		align: 'center'
					  	}, {
					  		field: 'rili',
					  		title: '排班日历',
					  		align: 'center',
							templet:function(d){
									return `<i class="layui-icon layui-icon-tabs"></i>`
							}
					  	}
					]]
					,data:data
				  });
			})
			$(function(){
				$("#addBtn").click(function(){
					top.tabAdd('巡检新增','xunjian_add','pages/xunjian/xunjian_add.html',true,true);
					
				})
			})
		</script>
	</body>
</html>
